package com.springboot.demo.design.pattern.listen;

import com.springboot.demo.design.pattern.Account;
import org.springframework.stereotype.Component;

/**
 * 创建账户监听器
 *
 * @author supu
 * @date 2019-07-02 14:30
 **/
@Component
public class CreateAccountListener<T extends ListenerContext> implements Listener<T> {
    @Override
    public void listen(T context) {
        Account account = (Account) context.getData();
        System.out.println("create account is process, account=" + account);
    }
}
